<template>

  <div class="tabZujian">
    <h1>选项卡切换，下面的内容变化</h1>
    <el-tabs v-model="activeName">
      <el-tab-pane label="tab1" name="first" :key="'first'">
        <child1></child1>
      </el-tab-pane>

      <el-tab-pane label="tab2" name="second" :key="'second'">
        <child2></child2>
      </el-tab-pane>
    </el-tabs>

  </div>
</template>

<script>
  import tabZujianChild1 from './zhytest1'
  import tabZujianChild2 from './zhytest2'
  export default {
    name: "zhytest5.vue",
    components:{
      child1:tabZujianChild1,
      child2:tabZujianChild2
    },
    data() {
      return {
        //默认第一个选项卡
        activeName: "first",
      }
    },
    mounted(){

    }
  }
</script>

<style scoped>

</style>
